<template>
    <div id="AsnDetails">
        <v-details :detailData="data.detailData" :inputConfig="inputConfig" @pop="setdata" :rules="rules"></v-details>
    </div>
</template>

<script>

    import details from 'commons/Detail'
    import baseMixin from "@/mixins/BaseMixin";

    export default {
        name: "",
        mixins: [baseMixin],
        props: {
            data: {
                type: Object
            }
        },
        data() {
            return {
                rules: {},
            }
        },
        computed: {
            inputConfig() {
                return [
                    [
                        {
                            type: "table",
                            label: this.$t('config.loc'),
                            props: "loc_code",
                            tableConfig: [
                                {
                                    label: this.$t('config.loc'),
                                    prop: "loc_code",
                                    input: "input",
                                }
                            ],
                            url: `/queryLocList/?/${this.$store.state.wms}`
                        }
                    ],
                ]
            }
        },
        methods: {
            setdata(data, id, close, listId) {
                this.data.detailData.loc_code = data.loc_code;
                close(false);
            }
        },
        mounted() {
        },
        watch: {},
        components: {
            'v-details': details
        }
    }
</script>

<style scoped>

</style>
